using UnityEngine;
using QFramework;
using System;
using Microsoft.Unity.VisualStudio.Editor;
namespace ProjectindieFarm
{
	public partial class UIbox : ViewController
	{
		void Start()
		{
			// Code Here
			SelectHide();
			select1.Show();

		}
		void Update()
		{
			if(Input.GetKeyDown(KeyCode.Alpha1))
			{
				Global.CurrentTool.Value = Constant.TOOL_HAND;
				Global.Player.PlayerTool.sprite = mage1.sprite;
				SelectHide();
				select1.Show();

			}
			if(Input.GetKeyDown(KeyCode.Alpha2))
			{
				Global.CurrentTool.Value = Constant.TOOL_SHOVEL;
				SelectHide();
				select2.Show();


			}
			if(Input.GetKeyDown(KeyCode.Alpha3))
			{
				Global.CurrentTool.Value = Constant.TOOL_SEED;
				SelectHide();				
				select3.Show();

			}
			if(Input.GetKeyDown(KeyCode.Alpha4))
			{
				Global.CurrentTool.Value = Constant.TOOL_WATERING_SCAN;
				SelectHide();
				select4.Show();

			}
		}
		void ChangeTool(String tool)
		{
			Global.CurrentTool.Value = tool;
			// AudioBehaviour.Get.SfxTake.Play();

		}
		void SelectHide()
		{
			select1.Hide();
			select2.Hide();
			select3.Hide();
			select4.Hide();
		}
	}
}
